package com.yangwei.examination.student.pojo;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yangwei.examination.teacher.pojo.*;
import com.yangwei.examination.user.pojo.Student;
import com.yangwei.examination.user.pojo.Teacher;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.time.LocalDateTime;
import java.util.List;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class AnswerPaper {
    @TableId(type = IdType.AUTO)
    private Long id;
    private Long studentId;
    private Long examId;
    private Long paperId;

    @TableField(value = "submit_Time", fill = FieldFill.INSERT_UPDATE)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime submitTime;

    @TableField(exist = false)
    private Exam exam;
    @TableField(exist = false)
    private Paper paper;
    @TableField(exist = false)
    private List<AnswerPaperQuestion> answerPaperQuestionList;
    //用于学生查答卷是否已经批改
    @TableField(exist = false)
    private Integer isCorrect=0;
    @TableField(exist = false)
    private Student student;

    @TableField(exist = false)
    private CorrectAnswerPaper correctAnswerPaper;  //用于统计导出csv



}
